<?xml version="1.0" encoding="utf-8" ?>
<taskrunner name="add.database.user" version="1.0" date="2008-06-19" maxthreads="1">

	<!-- attaches databases to sql server express. -->

	<includes>
		<file name="vida.install.settings.xml" />
	</includes>

	

	<tasks>
		<task name="add.login"  typename="@SqlServerManagement.AddLogin" retry="3">
      <errormessage>
        Could not add login 'ASUser' in Sql Server.
      </errormessage>
      <parameters>
				<parameter name="server" value="${sqlserver.local.server}"/>
				<parameter name="userid" value="${sqlserver.local.userid}"/>
				<parameter name="password" value="${sqlserver.local.password}"/>
				<parameter name="login.name" value="ASUser"/>
				<parameter name="login.password" value="GunnarS3g3"/>
				<parameter name="role.list" value="sysadmin"/>
			</parameters>
		</task>

		<task name="add.user" typename="@SqlServerManagement.AddDatabaseUser" retry="3">
			<dependencies list="add.login"/>
      <errormessage>
        Could not add database user 'ASUser' in Sql Server.
      </errormessage>
			<parameters>
				<parameter name="server" value="${sqlserver.local.server}"/>
				<parameter name="userid" value="${sqlserver.local.userid}"/>
				<parameter name="password" value="${sqlserver.local.password}"/>
				<parameter name="login.name" value="ASUser"/>
				<parameter name="database.list" value="${db.servicerepository.name},${db.basedata.name},${db.imagerepository.name},${db.accessserver.name},${db.epc.name},${db.diagswdlrepository.name}"/>
				<parameter name="role.list" value="db_owner,db_datareader"/>
				
			</parameters>
		</task>
	</tasks>
</taskrunner>